<?php

namespace App\Entity\Inbound;

class InboundEntity
{
    const TYPE_UNKNOWN = 0;
    const TYPE_PURCHASE = 1;// 采购入库
    const TYPE_RETURN = 2;// 退货入库
    const TYPE_SAMPLE = 3;// 样品入库
    const TYPE_TRANSFER = 4;// 移库入库
    const TYPE_OTHER = 99;

    public static function getTypeName($type)
    {
        $msg = [
            self::TYPE_UNKNOWN => '未知',
            self::TYPE_PURCHASE => '采购入库',
            self::TYPE_RETURN => '退货入库',
            self::TYPE_SAMPLE => '退货入库',
            self::TYPE_TRANSFER => '移库入库',
            self::TYPE_OTHER => '其他入库',
        ];

        return $msg[$type];
    }
}
